use crate::handlers::menu_handler as MenuHandler;
use actix_web::{web, Scope};

pub struct MenuRoutes;

impl MenuRoutes {
    pub fn init() -> Scope {
        web::scope("/menu")
            .route("/create", web::post().to(MenuHandler::create))
            .route("/delete", web::post().to(MenuHandler::delete))
            .route("/update", web::post().to(MenuHandler::update))
            .route("/detail", web::get().to(MenuHandler::detail))
            .route("/list", web::get().to(MenuHandler::list))
    }
}
